﻿
using StrokeCenterSystem.Core;
using StrokeCenterSystem.ThreeCenterManage;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;

namespace StrokeCenterSystem.Code.Bll
{
    /// <summary>
    /// 检验结果相关接口
    /// </summary>
    public class InspectionResultManager
    {
        /// <summary>
        /// 获取检验结果数据
        /// </summary>
        /// <param name="triageId">门诊ID</param>
        /// <returns></returns>
        public static OperateResult getInspectionInfor(string triageId)
        {
            OperateResult resultInfo = new OperateResult();
            try
            {
                ThreeCenterManageSoapClient service = new ThreeCenterManageSoapClient();
                ResultHelperOfString result = service.getInspectionInfor(triageId);
                if (result.S)
                {
                    resultInfo.Body = result.D;
                }
                else
                {
                    resultInfo.Result = 0;
                    resultInfo.Body = result.M;
                }
            }
            catch (Exception ex)
            {
                resultInfo.Result = -1;
                resultInfo.Body = ex.Message;
            }
            return resultInfo;
        }
    }
}